using System;
using UnityEngine;

public static class ZombieModePlayerStatistics
{
	public static float enterGameModeTime;

	public static float surviveTimeInSeconds;

	public static int killsAsHuman;

	public static int killsAsZombie;

	public static bool wasInfected;

	public static PunTeams.Team team;

	public static void ResetStatistics()
	{
		enterGameModeTime = 0f;
		surviveTimeInSeconds = 0f;
		killsAsHuman = 0;
		killsAsZombie = 0;
		wasInfected = false;
		team = PunTeams.Team.none;
	}

	public static void AddKill()
	{
		switch (team)
		{
		case PunTeams.Team.blue:
			killsAsHuman++;
			break;
		case PunTeams.Team.red:
			killsAsZombie++;
			break;
		}
	}

	public static void SetSurvivedTime()
	{
		if (team == PunTeams.Team.blue)
		{
			float f = (float)((double)enterGameModeTime - Convert.ToDouble(PhotonNetwork.room.customProperties["StartRoundTime"]));
			surviveTimeInSeconds = (float)PVPManager.instance.GetTime() - Mathf.Abs(f);
		}
	}
}
